//===================================================================
// 西交投.NET产品框架 版权所有
//===================================================================
using System;
using System.ComponentModel.DataAnnotations;
using XCI.Core;

namespace XCI.Sys.Model
{
    /// <summary>
    /// 系统登录日志
    /// @author 吕艳阳
    /// </summary>
    [ApiModel(Caption = "系统登录日志")]
    public class SysLoginLog
    {
        /// <summary>
        /// 主键
        /// </summary>
        [Display(Name ="主键")]
        [ApiModelProperty(PrimaryKey = true)]
        public string Id { get; set; }

        /// <summary>
        /// 登录类型 [1-登录, 2-注销]
        /// </summary>
        [Display(Name ="登录类型值")]
        public int Category { get; set; }

        /// <summary>
        /// 登录类型名称
        /// </summary>
        [Display(Name = "登录类型")]
        public string CategoryName { get; set; }

        /// <summary>
        /// 用户主键
        /// </summary>
        [Display(Name = "用户主键")]
        public string UserId { get; set; }

        /// <summary>
        /// 用户姓名
        /// </summary>
        [Display(Name = "用户姓名")]
        public string UserName { get; set; }

        /// <summary>
        /// 用户账号
        /// </summary>
        [Display(Name = "用户账号")]
        public string UserAccount { get; set; }

        /// <summary>
        /// 登录状态 [true-成功, false-失败]
        /// </summary>
        [Display(Name = "登录状态")]
        public bool Status { get; set; }

        /// <summary>
        /// 操作信息
        /// </summary>
        [Display(Name = "操作信息")]
        public string Msg { get; set; }

        /// <summary>
        /// 应用主键
        /// </summary>
        [Display(Name = "应用主键")]
        public string AppId { get; set; }

        /// <summary>
        /// 应用名称
        /// </summary>
        [Display(Name = "应用名称")]
        public string AppName { get; set; }

        /// <summary>
        /// IP地址
        /// </summary>
        [Display(Name = "IP地址")]
        public string Ip { get; set; }

        /// <summary>
        /// IP地点
        /// </summary>
        [Display(Name = "IP地点")]
        public string IpLocation { get; set; }

        /// <summary>
        /// 浏览器
        /// </summary>
        [Display(Name ="浏览器")]
        public string Browser { get; set; }

        /// <summary>
        /// 操作系统
        /// </summary>
        [Display(Name ="操作系统")]
        public string Os { get; set; }

        /// <summary>
        /// 浏览器标识
        /// </summary>
        [Display(Name = "浏览器标识")]
        public string UserAgent { get; set; }

        /// <summary>
        /// 登录时间
        /// </summary>
        [Display(Name ="登录时间")]
        public DateTime? OperateDateTime { get; set; }

        /// <summary>
        /// 复制对象
        /// </summary>
        public SysLoginLog Clone()
        {
            return (SysLoginLog)MemberwiseClone();
        }
    }
}
